package com.ruoyi.camp.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.camp.mapper.CampFacilityMapper;
import com.ruoyi.camp.domain.CampFacility;
import com.ruoyi.camp.service.ICampFacilityService;

/**
 * 营地设施Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-11-19
 */
@Service
public class CampFacilityServiceImpl implements ICampFacilityService 
{
    @Autowired
    private CampFacilityMapper campFacilityMapper;

    /**
     * 查询营地设施
     * 
     * @param cfid 营地设施主键
     * @return 营地设施
     */
    @Override
    public CampFacility selectCampFacilityByCfid(String cfid)
    {
        return campFacilityMapper.selectCampFacilityByCfid(cfid);
    }

    /**
     * 查询营地设施列表
     * 
     * @param campFacility 营地设施
     * @return 营地设施
     */
    @Override
    public List<CampFacility> selectCampFacilityList(CampFacility campFacility)
    {
        return campFacilityMapper.selectCampFacilityList(campFacility);
    }

    /**
     * 新增营地设施
     * 
     * @param campFacility 营地设施
     * @return 结果
     */
    @Override
    public int insertCampFacility(CampFacility campFacility)
    {
        return campFacilityMapper.insertCampFacility(campFacility);
    }

    /**
     * 修改营地设施
     * 
     * @param campFacility 营地设施
     * @return 结果
     */
    @Override
    public int updateCampFacility(CampFacility campFacility)
    {
        return campFacilityMapper.updateCampFacility(campFacility);
    }

    /**
     * 批量删除营地设施
     * 
     * @param cfids 需要删除的营地设施主键
     * @return 结果
     */
    @Override
    public int deleteCampFacilityByCfids(String[] cfids)
    {
        return campFacilityMapper.deleteCampFacilityByCfids(cfids);
    }

    /**
     * 删除营地设施信息
     * 
     * @param cfid 营地设施主键
     * @return 结果
     */
    @Override
    public int deleteCampFacilityByCfid(String cfid)
    {
        return campFacilityMapper.deleteCampFacilityByCfid(cfid);
    }
}
